<template>
  <div class="content">
      <div v-for="item in allRooms.list" :key="item.id">
        <img src="../../images/home-cz/leisure.png" alt="" v-if="item.roomState == 0">
        <img src="../../images/home-cz/youren.png" alt="" v-else-if="item.roomState == 1">
        <img src="../../images/home-cz/claen.png" alt="" v-else>
        <span class="roomnumber">{{item.roomNum}}</span>
        <span class="number">{{item.numberofpeopleserved}}/2</span>
      </div>
  </div>
</template>

<script>
import {createNamespacedHelpers} from "vuex";
const {mapActions,mapState,mapMutations} = createNamespacedHelpers("homecontent");
export default {
   mounted() {
    //  console.log(this.data.list);
        this.getRoom()
    },
     methods: {
      ...mapActions(["getRoom"]),
    },
   computed: {
      ...mapState(["allRooms"]),
    },
}
</script>

<style lang="scss" scoped src="../../css/all.scss"></style>